package com.yzf.controller;

import java.util.List;
import java.util.Map;

import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.yzf.dao.DemoDao;
import com.yzf.service.DemoService;

@Controller
@RequestMapping("test")
public class TestController {
	
	private Logger logger=Logger.getLogger(this.getClass());
	
	@Autowired
	DemoService demoService;
	
	@RequestMapping("login")
	public String test1(){
		
		System.out.println("登录");
		List<Map<String, Object>> list = (List<Map<String, Object>>) demoService.demo();
		
		logger.info("数据:" + list);
		System.out.println("list:"+list);
		return "/ht/main"; 
	}
}
